package cn.meike.net.protocol;

import org.apache.mina.core.buffer.IoBuffer;

public class LoginServer_Request 
{
	
	public int m_uiUin;
	public int m_uiSeq;
	
	public int encode(IoBuffer buff)
	{
		buff.putInt(m_uiUin);
		buff.putInt(m_uiSeq);
		return 0;
	}
	
	public int decode(IoBuffer buff)
	{
		int _savedBuffBeginPos = buff.position();

		if(buff.remaining() < 4)
		{
			return -1;
		}
		
		m_uiUin = buff.getInt();
		
		if(buff.remaining() < 4)
		{
			return -1;
		}
		m_uiSeq = buff.getInt();
		
		return 0;
	}
	

}
